#!/bin/bash

server="manage.py"
if [ ! -d "logs" ]; then mkdir "logs"; fi;

ps aux | grep $server | grep -v grep | awk '{print $2}' | xargs kill -9

if [ ! -f "$server" ]; then server="$server"c;fi
nohup python $server -m -d -p 20800 >/dev/null &
#nohup python $server -p 20801  >/dev/null &